import Vue from "vue";
import VueRouter from "vue-router";
import Index from "../views/Index.vue";

Vue.use(VueRouter);

const routes = [
  {
    path: "/",
    name: "Index",
    component: Index,
    children: [
      {
        path: "/",
        name: "Home",
        component: () =>
            import(/* webpackChunkName: "about" */ "../views/Home.vue"),
        meta:{title:'天昊天玺'}
      },
      {
        path: "/qrCode",
        name: "QrCode",
        component: () =>
            import(/* webpackChunkName: "about" */ "../views/QrCode.vue"),
        meta:{title:'推荐二维码'}
      },
      {
        path: "/mine",
        name: "Mine",
        component: () =>
            import(/* webpackChunkName: "about" */ "../views/Mine.vue"),
        meta:{title:'个人中心'}
      }
    ]
  },
  {
    path: "/detail",
    name: "Detail",
    component: () => import("../views/Detail.vue"),
    meta:{title:'商品详情'}
  },
  {
    path: "/level",
    name: "Level",
    component: () => import("../views/Level.vue"),
    meta:{title:'我的推荐'}
  },
  {
    path: "/log",
    name: "Log",
    component: () => import("../views/Log.vue"),
    meta:{title:'操作日志'}
  },
  {
    path: "/order",
    name: "Order",
    component: () => import("../views/Order.vue"),
    meta:{title:'商品订单'}
  },
  {
    path: "/money",
    name: "Money",
    component: () => import("../views/Money.vue"),
    meta:{title:'我的资金'}
  },
  {
    path: "/takes",
    name: "Takes",
    component: () => import("../views/Takes.vue"),
    meta:{title:'提现记录'}
  },
  {
    path: "/signs",
    name: "Signs",
    component: () => import("../views/Signs.vue"),
    meta:{title:'上课记录'}
  },
  {
    path: "/login",
    name: "Login",
    component: () => import("../views/Login.vue"),
    meta:{title:'登录'}
  },
  {
    path: "/verify",
    name: "Verify",
    component: () => import("../views/Verify.vue"),
    meta:{title:'核验页'}
  },

];

const router = new VueRouter({
  mode: "history",
  base: "/dist/",
  routes
});

export default router;
